#include "handMoveRecog.h"

Point2f handMove::getPointMean(){return pointMean;}
Point2f handMove::getScaleMean(){return scaleMean;}
Point2f handMove::getPointVar(){return pointVar;}
Point2f handMove::getScaleVar(){return scaleVar;}

void handMove::calcFlowMeanVar(std::vector<Point2f> flowPoint, std::vector<Point2f> flowScale)
{
  vector< pair<P2d,P2d> > vals;
  convertflowPoint2P2d(flowPoint, flowScale, &vals);
  pair<P2d,P2d> mean_temp,var_temp;
  calcMeanVar(vals, &mean_temp, &var_temp);
  pointMean.x = mean_temp.first.first; pointMean.y = mean_temp.first.second;
  scaleMean.x = mean_temp.second.first; scaleMean.y = mean_temp.second.second;
  pointVar.x = var_temp.first.first; pointVar.y = var_temp.first.second;
  scaleVar.x = var_temp.second.first; scaleVar.y = var_temp.second.second;
}
